package com.cuit.washneedshake.mapper;

import com.cuit.washneedshake.model.entity.NationalProvinces;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper
public interface NationalProvincesMapper extends BaseMapper<NationalProvinces> {
    /*
     * 获取累计感染人数排名前十的省份，从高到低排序
     */
    @Select("select province from national_provinces order by confirmed desc limit 0,10")
    List<String> getConfirmProvinces();

    /*
     * 获取各省份累计感染排名前十的人数，从高到低排序
     */
    @Select("select confirmed from national_provinces order by confirmed desc limit 0,10")
    List<Integer> getConfirmNumber();
}




